package com.yhn.registration.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hospital.common.pojo.TDepartment;
import com.hospital.common.pojo.TDoctorInfo;
import com.hospital.common.pojo.TDoctorSchedule;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface DepartmentMapper extends BaseMapper<TDepartment> {
    List<TDepartment> listAll();

    List<TDoctorInfo> doctor();

    List<TDoctorInfo> doctorByDept(@Param("deptId") Long deptId);

    List<TDoctorInfo> getDoctorByName(@Param("name") String name);

    List<TDoctorSchedule> getDoctorSchedule(@Param("doctorId") Long doctorId);

    List<TDoctorInfo> doctorsByDeptAndSchedule(@Param("deptId") Long deptId,
                                              @Param("date") String date,
                                              @Param("hourSlot") Integer hourSlot);

    String getDoctorNameByInfoId(@Param("infoId") Long infoId);

    Long getUserIdByInfoId(@Param("infoId") Long infoId);
}


